<template>
    <!-- <van-button type="primary">点击 </van-button>  -->
    <van-search v-model="value" shape="round" background="#4fc08d" placeholder="请输入搜索关键词" show-action @cancel='quxiao' />
    <SearchResult />
    <SearchSuggestion />
    <SearchHistory />

</template>

<script >
// 1 三个组件 通过输入框事件进行切换

// 先导入子组件, 然后再注册子组件  最后  使用
import SearchResult from "./components/jieguo.vue";
import SearchSuggestion from "./components/jianyi.vue";
import SearchHistory from "./components/lishi.vue";


export default {
    // 来自app.vue 的工具函数 用来无感刷新页面
    //   inject: ['reload'],
    data() {
        return {
            value: '123123',
            value2: '777888',

        }
    },
    components: {
        SearchResult,
        SearchSuggestion,
        SearchHistory,
    },
    methods: {
        quxiao() {
            debugger
            console.log('取消');
        },
    }
}
</script>

<style></style>